The format of length values is an optional sign character ('+' or '-', with '+' being the default) immediately followed by a number (with or without a decimal point) immediately followed by a unit identifier (a two-letter abbreviation).

There are three types of length units: relative, pixel and absolute. Relative units specify a length relative to another length property. The following relative units are supported: (NOTE : The elements shown are used as an example, the settings can be applied to any element)

H1 { margin: 0.5em }ems, the height of the element's font
H1 { margin: 1ex }x-height, ~ the height of the letter 'x'
P { font-size: 12px }pixels, relative to canvas

Pixel units, as used in the last rule, are relative to the resolution of the screen display.

The following absolute units are supported: (NOTE : The elements shown are used as an example, the settings can be applied to any element)

H1 { margin: 0.5in }inches, 1in = 2.54cm
H2 { line-height: 3cm }centimeters
H3 { word-spacing: 4mm }millimeters
H4 { font-size: 12pt }points, 1pt = 1/72 in
H4 { font-size: 1pc }picas, 1pc = 12pt


Classification Properties Properties and Values Percentage units